package ir.values;

import ir.types.Type;

public abstract class Value {
    protected String originalName;
    protected int id;
    protected Type type;

    public Value(String originalName, Type type) {
        this.originalName = originalName;
        this.type = type;
    }

    public Type getType() {
        return type;
    }
    public String getOriginalName() {
        return originalName;
    }
    public String parseUsingName() {
        if (originalName != null) {
            return "@" + originalName;
        }
        else {
            return null;
        }
    }
    public abstract String parseLLVM();
    public void setId(int id) {
        this.id = id;
    }

}
